|
|
|
|
|
|
|
Figure 14.25
Two Bezier surfaces joined smoothly at an edge. |
|
|
|
|
|
|
|
|
While this gives you a good deal of flexibility, it also places you under quite a few constraints. If you move a control point on the edge of a surface, you must also move the corresponding control points on any surfaces that share the point. If you want the surfaces to meet smoothly, you also need to move the neighboring control points so that they still lie along a straight line. When you move one of those neighboring control points, you also need to make adjustments to keep the points properly aligned. |
|
|
|
|
|
|
|
|
Like two-dimensional B-spline curves, three-dimensional B-spline surfaces give you local control over your surface without all of these constraints. As is the case with two-dimensional B-splines, B-spline surfaces are defined in terms of blending functions that generate the points on the surface as weighted averages of the control points' coordinate values. |
|
|
|
|
|
|
|
|
Suppose you have a two-dimensional grid of control points as before with coordinates stored in the arrays ControlX(0 To M, 0 To N), ControlY(0 To M, 0 To N), and ControlZ(0 To M, 0 To N). Then the X coordinates of the points on the B-spline surface are given by the equation: |
|
|
|
|
|